const express=require('express');
const xiajunhui = require('../uilit/mysql');
const NEIRONG=express.Router();
NEIRONG.post('/neirong',(req,res)=>{
    console.log(req.body.zhiweiID);
    const zhiweiID = req.body.zhiweiID;
    const sql =`SELECT*FROM company WHERE c_id=${zhiweiID};`;
    xiajunhui.query(sql,(err,data)=>{
        if(err){
            res.send({kill:1,msg:err})
        }else{
            console.log(data)
            res.send({kill:0,msg:'输出成功',data:data})
        }
    })
})
NEIRONG.post('/toubuxinxi',(req,res)=>{
    // const zhiweiID = req.query.zhiweiID;
    // const sql =`SELECT*FROM company WHERE c_id=${zhiweiID};`;
    // xiajunhui.query(sql,(err,data)=>{
    //     if(err){
    //         res.send({kill:1,msg:err})
    //     }else{
    //         console.log(data)
    //         res.send({kill:0,msg:'输出成功',data:data})
    //     }
    // })
})
module.exports=NEIRONG;